import request from '@/utils/request'
// 获取权限列表
export function getPermissionList(params){
    return request({
        url:'/sys/permission',
        params
    })
}

// 新增权限
export function  addPermission(data){
    return request({
        url:'/sys/permission',
        method:'post',
        data
    })
}

// 删除权限
export function delPermission(id){
    return request({
        url:`/sys/permission/${id}`,
        method:'delete'
    })
}

// 更新权限
export function updatePermission(data){
    return request({
        url:`/sys/permission/${data.id}`,
        method:'put',
        data
    })
}